/**
 * code highlight style
 */
hljs.initHighlightingOnLoad();


authorInfoPosition = function () {

  var never1 = $("#content-left").offset().top;
  var never2 = $(document).scrollTop();

  var $author = $("#author-info");

  /**
   * IE
   */
  // document.documentElement.clientWidth

  if (window.innerWidth < 900) {
    $author.removeAttr('style');
    return;
  }

  if (parseInt(never1 - never2) < 0) {
    $author.css('position','fixed');
    $author.css('top','20px');
  } else {
    $author.removeAttr('style');
  }
};


authorInfoPosition();

/**
 * content-left author info fixed
 */
window.onscroll = authorInfoPosition;

